import request from '@/config/axios'

export interface MgmtDefectiveProductDeterminationVO {
  id: number
  inspectionTaskCode: string
  productCode: string
  partCode: string
  partName: string
  defectiveQuantity: number
  drawingNumber: string
  dictInspectionType: number
  dictStatus: number
  description: string
  dictFinalConclusion: number
  inspectionNotes: string
  customerName: string
  unit: string
}

// 查询质量管理-品质管理-异常品判定列表
export const getMgmtDefectiveProductDeterminationPage = async (params) => {
  return await request.get({ url: `/quality/mgmt-defective-product-determination/page`, params })
}

// 查询质量管理-品质管理-异常品判定详情
export const getMgmtDefectiveProductDetermination = async (id: number) => {
  return await request.get({ url: `/quality/mgmt-defective-product-determination/get?id=` + id })
}


// 修改质量管理-品质管理-异常品判断
export const updateMgmtDefectiveProductDetermination = async (data: MgmtDefectiveProductDeterminationVO) => {
  return await request.put({ url: `/quality/mgmt-defective-product-determination/update`, data })
}


// 导出质量管理-品质管理-异常品登记 Excel
export const exportMgmtDefectiveProductDetermination = async (data) => {
  return await request.download({ url: `/quality/mgmt-defective-product-determination/export-excel`, data })
}

